package mycollections;

import java.util.Iterator;

public interface MyMap<K,V> {

	void clear();// - removes all of the mappings from this map.
	boolean containsKey(K key);// - returns true if this map contains a mapping for the specified key.
	boolean containsValue(V value);// - returns true if this map maps one or more keys to the specified value.
	V get(K key);// - returns the value to which the specified key is mapped, or null if this map contains no mapping for the key.
	boolean isEmpty();// - returns true if this map contains no key-value mappings.
	V put(K key, V value);// - associates the specified value with the specified key in this map.
	Object remove(K key);// - removes the mapping for the specified key from this map if present.
	int size();// - returns the number of key-value mappings in this map.
	Iterator<MyMap.Entry<K, V>> entryIterator();// - returns an iterator over the elements (MyMap.Entry) in proper sequence
	
	public interface Entry<K,V> {
		boolean equals(Object o);// - �ompares the specified object with this entry for equality.
		K getKey();// - returns the key corresponding to this entry.
		V getValue();// - returns the value corresponding to this entry.
		int hashCode();// - returns the hash code value for this map entry.
		V setValue(V value);// - replaces the value corresponding to this entry with the specified value.
	}
	
}
